package com.example.springcloudfeignprovider02.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.Map;

/**
 * @author X.I.O
 * @title: ProviderController
 * @projectName spring-cloud-1
 * @description: TODO
 * @date 2021/11/3 0:39
 */
@RestController
@RequestMapping("/test")
public class ProviderController {

    @GetMapping("/test111")
    public Map<String, Object> objectController() {
        Map<String, Object> objectMap = new HashMap<>();
        objectMap.put("code", 1);
        objectMap.put("msg", "我说服务提供者222");
        return objectMap;
    }
    @GetMapping("test222")
    public String hetTestController() throws Exception{
        Thread.sleep(10000);
        return "哈哈";
    }
}
